package com.bw.comtroller;

import com.bw.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

//controller层
@RestController
public class UserController {
    //调用service方法
    @Autowired
    UserService userService;

    //实现查询 多条件组合查询
    @RequestMapping("/list")
    public List getList(String address, String realName){
        return userService.getList(address,realName);
    }

    //实现删除
    @RequestMapping("/del")
    public int del(int[] ids){
        return userService.del(ids);
    }
}
